home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
AEMail 2.40
/
AEMail v2.40.iso
/
arexx
/
subscribe.readme
< prev
next >
Wrap
Text File
|
1999-03-24
|
4KB
|
103 lines
Name: subscribe.aem
TO BE USED BY REGISTERED USER'S ONLY
This ARexx script is used to add names to a group entry in the Address Book
for individuals that subscribe or unsubscribe to a mailing list.
When individuals wish to subscribe to a mailing list they place "subscribe"
and the mailing list name in the body of a message.
To unsubscribe, they would place "unsubscribe" and the name of the mailing
list in the body of the message.
HOW TO IMPLEMENT
----------------
This is a generic script that can be used to set up multiple mailing lists.
There are certain rules you must follow for this script to work. You could
probably develop a simpler script for a subscription to a specific mailing
list without requiring the rules set forth here. These rules make the
script generic.
The rules:
(1) You must set up a folder for the subscribe/unsubscribe messages.
This folder must have a body filter that contains:
"subscribe *[mailing-list-name]"
and should be case insensitive. This filter will capture both
subscibe and unsubscribe messages and direct them to this folder.
Please note the two spaces and the * following "subscribe". This
allows any number (but a least one) spaces to separate "subscribe"
from the mailing list name.
(2) The short name given to this folder must match the Nickname for the
mailing list group in your address book. You must create a group
in your Address book for the mailing list BEFORE executing this
script. That is because the script searches for a group Nickname
that matches the short folder name that contains the
subscribe/unsubscribe messages.
This script is probably best placed in your REXX: directory. If you wish
to modify this script please note the following items:
Avoid any variable names that might match an AEMail ARexx command or a
standard ARexx command.
Note the use of "'" surrounding the email variable in the EXTRACT
command. This will pass the single quote to AEMail surrounding the
name extracted from the FROM string. AEMail will strip the single
quote preserving any double quotes which might surround the name in
the FROM string. If you were to use '"' instead of "'", the proper
action would not occur.
The PARSE command will extract the variable "listname". That vaiable
is not used with this script. If you use this variable to identify
the list be sure and strip any beginning or ending spaces from the
variable.
WHAT THE SCRIPT DOES
--------------------
When this script is executed it will obtain a list of all of your folder
names. It will then match each name to a Address Book group Nickname. If
a match is found, it will assume that this folder contains subscribe/
unsubscribe messages for this group.
The script will then obtain the text body of each NEW message and search
for the subscribe or unsubscribe key word. If it is a "subscribe" message
it will add the email address in the REPLY-TO or FROM (if REPLY-TO is
missing) header to the mailing list.
If it is a "unsubscribe" message it will delete the email address from the
group.
It does not matter if a "subscribe" email address is already in the group
or if a "unsubscribe" email address is missing from the group.
It can not delete the last address in a group. It is best to set up the
group with a known email address that you will always know is in the group
(such as your own).
After processing the "new" message, the message indicator for read will be
turned on.
HOW TO USE
----------
After you receive messages simply execute this script. If any new
"subscribe" or "unsubscribe" messages were received, it will add or delete
them from the Address Book group entry. If none were received, nothing
happens.
It is best to be displaying a message from another folder when you execute
this script. This will speed up the execution of the script. If a message
is not being displayed, each time a message is marked as read, the message
list for the folder will be re-displayed. By displaying a message, you
will avoid this condition.